package com.example.ai.model.api

import com.example.ai.model.data.BaseResponse
import retrofit2.http.GET
import retrofit2.http.POST
import retrofit2.http.Query

/**
 * Created by lijinxi on 2024/3/13.
 * @Description:
 */
interface ApiNew {
    companion object {
        const val GET_CHAT = "/api/commop/ai_person/chat"
        const val GET_VOICE = "/api/commop/ai_person/get_voice_url"
        const val GEN_TALK = "/api/commop/ai_person/generate_talk"
        const val GET_TALK = "/api/commop/ai_person/get_talk"
    }

    @POST(GET_CHAT)
    suspend fun getChatText(@Query("message") message: String): BaseResponse?

    @POST(GET_VOICE)
    suspend fun getVoice(
        @Query("text") text: String,
        @Query("speaker") speaker: String
    ): BaseResponse?

    @POST(GEN_TALK)
    suspend fun generateTalk(
        @Query("audioUrl") audioUrl: String,
        @Query("picUrl") picUrl: String
    ): BaseResponse?

    @POST(GET_TALK)
    suspend fun getTalk(@Query("talkID") talkID: String): BaseResponse?
}